﻿using ShanNiang.Mvvm.ViewModels;
using ShanNiang.Service.Attributes;
using ShanNiang.Service.Constants;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Versioning;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;

namespace ShanNiang.Packing.UserControls
{
    /// <summary>
    /// PackPalletControl.xaml 的交互逻辑
    /// </summary>
    [MenuControl(CommonData.MENU_PACKPALLET, "装托", 2, CommonData.MENU_ICON_PACKPALLET)]
    [SupportedOSPlatform("windows")]
    public partial class PackPalletControl : UserControl
    {
        private readonly PackPalletViewModel _packPalletViewModel;
        public PackPalletControl(PackPalletViewModel packPalletViewModel)
        {
            InitializeComponent();
            DataContext = packPalletViewModel;
            _packPalletViewModel = packPalletViewModel;
        }

        private void Grid_PreviewKeyDown(object sender, KeyEventArgs e)
        {
            e.Handled = true; // 取消回车键的默认行为
        }
    }
}
